import similaritycalc as sim
import numpy as np
import pandas as pd

df = pd.read_excel("database_0714.xlsx")
for i in range(len(df)):
    smi = "CCn1c(C(C)O)nn(CCCN2CCN(c3cccc(Cl)c3)CC2)c1=O"
    pubchem_id = 40589
    test_df = df.drop(df[df['PUBCHEM CID'] == pubchem_id].index)
    for j in range(len(test_df)):
        template = test_df["extract templates"][i]
        product_list = sim.apply_templates(smi, template)
        print(len(product_list))
    #break